<!DOCTYPE html>
<html lang="en">
<head>
	<meta charset="UTF-8">
	<title>数组</title>
	<script type="text/javascript">
		var arr = [];
		console.info(arr.length);
		arr[0] = 10;
		console.info(arr[1]);
		console.info(arr.length);
		arr[4]= 11;
		arr[2]= null;
		console.info(arr[1]);
		console.info(arr.length);

		for(var i =0;i<arr.length;i++){
			console.info("arr for "+i+"  :  "+arr[i])
		}

		for(var i in arr){
			console.info("arr for/in "+i+"  :  "+arr[i])
		}

		arr.length=3;

		console.info(arr.length);
		for(var i =0;i<arr.length;i++){
			console.info("222 arr for "+i+"  :  "+arr[i])
		}

		for(var i in arr){
			console.info("222 arr for/in "+i+"  :  "+arr[i])
		}
	</script>
</head>
<body>
	
</body>
</html>